From: Mary Boetcher, Mary_Boetcher@quickmail.apple.com
Reply-To: ODF Interest, ODF-Interest@CILabs.ORG
To: OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
Mail*LinkĀ® SMTP RE>Modal Dialogs: Part I
>I followed the example of ODFForm's Password dialog to create a text entry
>dialog. The action of the dialog when the "OK" button is hit is to post an
>undoable command.
>
>So the question is, is it OK to pass the dialog's frame to the FW_CCommand
>constructor? The frame will be destroyed when the dialog closes, right? But
>this seems to work - I guess I'm wondering what that parameter and the
>fFrame data member of FW_CCommand are all about. Comments?
The fFrame data member of a command represents the display frame that is affected by the change. In the case of a dialog you shouldn't pass the dialog frame to the command unless the command is undoable while the dialog is open. In your case fFrame is apparently not used in your UndoIt and RedoIt methods, so you're getting away with it.